//
//  DataCell.m
//  StationManager
//
//  Created by 张佳强 on 17/3/4.
//  Copyright © 2017年 Helong. All rights reserved.
//

#import "DataCell.h"

@implementation DataCell

- (void)awakeFromNib {
    [super awakeFromNib];
    // Initialization code
}

- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
    
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        
        self.firstSpaceLabel = [[UILabel alloc]initWithFrame:CGRectMake(0, 0, 10, 40)];
        self.firstSpaceLabel.backgroundColor = [UIColor whiteColor];
        [self.contentView addSubview:self.firstSpaceLabel];
        
        self.titleLabel = [[UILabel alloc]initWithFrame:CGRectMake(10, 0, 70, 40)];
        self.titleLabel.font = [UIFont systemFontOfSize:13.0];
        self.titleLabel.textAlignment = NSTextAlignmentCenter;
        self.titleLabel.backgroundColor = [UIColor whiteColor];
        [self.contentView addSubview:self.titleLabel];
        
        self.spaceLabel = [[UILabel alloc] init];
        [self.contentView addSubview:self.spaceLabel];
        
        self.dataLabel = [[UILabel alloc]init];
        self.dataLabel.font = [UIFont systemFontOfSize:13.0];
        [self.contentView addSubview:self.dataLabel];
        
        self.iconImageView = [[UIImageView alloc]init];
//        self.contentView.backgroundColor = [UIColor colorWithRed:239/255.0 green:239/255.0 blue:244/255.0 alpha:1.0];
        self.contentView.backgroundColor = [UIColor whiteColor];
        [self.contentView addSubview:self.iconImageView];
        
        [self.iconImageView mas_makeConstraints:^(MASConstraintMaker *make) {
            make.right.equalTo(@-1);
            make.bottom.equalTo(@-8);
            make.width.mas_equalTo(20);
            make.height.mas_equalTo(20);
        }];
    }
    return self;
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];
    
    // Configure the view for the selected state
}

@end
